<%@page language="java" contentType="text/html; charset=utf-8"
    pageEncoding="utf-8"%>
<div class="row">
		<div class="col-xs-10 col-xs-offset-1">
		<h2>反馈区</h2>
			
			<form class="form-group">
			
			<textarea id="msgText" style="width:100%" rows="10"></textarea>
			<br>
		  <div class="col-xs-3"><div class="form-inline">
		    <label for="name">刚问大侠名字</label>
		    <input type="text" class="form-control" id="name" placeholder="猪猪侠">
		  </div></div>
		  <div class="col-xs-3">
		  <div class="form-inline">
		    <label for="tel">敢问大侠联系(email,QQ,微信,手机)</label>
		    <input type="text" class="form-control" id="tel" placeholder="email,QQ,微信,手机">
		  </div></div>
		  <button id="feedback" class="btn btn-primary">反馈</button>
		</form>
		</div>
	</div>
	<script type="text/javascript">
		$(function(){
			$("#feedback").click(function(){
				var name = $("#name").val();
				var tel = $("#tel").val();
				var msg = $("#msgText").val();
				/* console.log($("#msgText"));
				console.log("text:"+$("#msgText").text());

				console.log("val:"+$("#msgText").val());

				console.log("html:"+$("#msgText").html()); */
				if(msg == ""){ alert("你还未输入任何反馈信息");return false;}
				var params = {name:name,tel:tel,msg:msg};
				console.log(params);
				$.ajax({url:"/fankui.html",type:"post",data:params,success:function(data){
					console.log(data);
					alert("感谢大侠的反馈！");
				}})
				return false;
			})
		})
</script>
    